//
//  requestManage.h
//  XYMaterial
//
//  Created by 肖扬 on 15/12/12.
//  Copyright © 2015年 肖扬. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "ASIHTTPRequest.h"
#import "ASIHTTPRequestDelegate.h"

/*
 * app接口函数
 * --公共数据
 * --登陆接口
 * --短信验证码接口
 * --注册接口
 * --用户信息
 * --首页
 * --我的供货订单
 * --我的采购订单
 * --直销商城
 * --今日特价
 * --采购模块
 * --货源接口
 * --认证接口
 * --认证图片
 * --修改密码
 * --搜索接口
 * --检测版本
 * --添加收藏
 * --删除收藏
 * --我要采购
 * --删除货源
 * --删除采购
 * --修改个人信息
 * --修改公司信息
 */
#define GETCOMMONDATA   @"/release/getcommondata"
#define LOGIN           @"/member/login"
#define SMS_CODE        @"/member/sms_code"
#define REGISTER        @"/member/register"
#define PROFILE         @"/member/profile"
#define HOME_INDEX      @"/home/index"
#define MYPURCHAESORDER @"/profile/mypurchaesorder"
#define MYSUPPLYORDER   @"/profile/mysupplyorder"
#define MYSUPPLY        @"/profile/mysupply"
#define MYPURCHAES      @"/profile/mypurchases"
#define SHOPGETLIST     @"/shop/getlist"
#define SALESGETLIST    @"/sales/getlist"
#define PURCHAESLIST    @"/purchaes/getlist"
#define SUPPLYLIST      @"/supply/getlist"
#define MYLICENSE       @"/profile/mylicense"
#define SETLICENSE      @"/profile/setlicense"
#define MYFOVOR         @"/profile/myfovor"
#define MODIFYPASSWORD  @"/profile/modifypassword"
#define MEMBERPASSWORD  @"/member/modifypassword"
#define SEARCHLIST      @"/search/getlist"
#define SYNCVERSION     @"/release/sync"
#define ADDFAVOR        @"/profile/addfavor"
#define DELFAVOR        @"/profile/delfavor"
#define INTENT          @"/purchaes/intent"
#define SUPPLYINTENT    @"/supply/intent"
#define DELSUPPLY       @"/profile/delsupply"
#define DELPURCHASE     @"/profile/delpurchase"
#define SETMEMBER       @"/profile/setMember"
#define SETCOMPANY      @"/profile/setcompany"
@interface requestManage : NSObject<ASIHTTPRequestDelegate>{
    BOOL isRequestFinish;
    NSMutableDictionary *postData;
}
@property (nonatomic, retain) NSMutableDictionary *postData;
@property (nonatomic, assign) BOOL isRequestFinish;
@property (nonatomic, assign) NSInteger timeOutSecond;
@property (nonatomic, retain)ASIHTTPRequest *request;

-(NSString *)get:(NSString *)url  error:(NSError **)error;

-(NSString *)post:(NSString *)url  postDataDic:(NSMutableDictionary *)dic error:(NSError **)error;

-(NSString *)post:(NSString *)url  postDic:(NSDictionary *)dic error:(NSError **)error;

- (void)cancel;

@end
